﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x02000193 RID: 403
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class CellAdvanceInfo : IMessage<CellAdvanceInfo>, IMessage, IEquatable<CellAdvanceInfo>, IDeepCloneable<CellAdvanceInfo>, IBufferMessage
	{
		// Token: 0x17000548 RID: 1352
		// (get) Token: 0x06001217 RID: 4631 RVA: 0x00033E94 File Offset: 0x00032094
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<CellAdvanceInfo> Parser
		{
			get
			{
				return CellAdvanceInfo._parser;
			}
		}

		// Token: 0x17000549 RID: 1353
		// (get) Token: 0x06001218 RID: 4632 RVA: 0x00033E9B File Offset: 0x0003209B
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return CellAdvanceInfoReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x1700054A RID: 1354
		// (get) Token: 0x06001219 RID: 4633 RVA: 0x00033EAD File Offset: 0x000320AD
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return CellAdvanceInfo.Descriptor;
			}
		}

		// Token: 0x0600121A RID: 4634 RVA: 0x00033EB4 File Offset: 0x000320B4
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellAdvanceInfo()
		{
		}

		// Token: 0x0600121B RID: 4635 RVA: 0x00033EBC File Offset: 0x000320BC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellAdvanceInfo(CellAdvanceInfo other) : this()
		{
			CellAdvanceInfo.AdvanceInfoOneofCase advanceInfoCase = other.AdvanceInfoCase;
			if (advanceInfoCase != CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
			{
				if (advanceInfoCase != CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
				{
					if (advanceInfoCase == CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
					{
						this.CellBossInfo = other.CellBossInfo.Clone();
					}
				}
				else
				{
					this.SelectBossInfo = other.SelectBossInfo.Clone();
				}
			}
			else
			{
				this.FinalBossInfo = other.FinalBossInfo.Clone();
			}
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x0600121C RID: 4636 RVA: 0x00033F2C File Offset: 0x0003212C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellAdvanceInfo Clone()
		{
			return new CellAdvanceInfo(this);
		}

		// Token: 0x1700054B RID: 1355
		// (get) Token: 0x0600121D RID: 4637 RVA: 0x00033F34 File Offset: 0x00032134
		// (set) Token: 0x0600121E RID: 4638 RVA: 0x00033F4D File Offset: 0x0003214D
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellMonsterInfo CellBossInfo
		{
			get
			{
				if (this.advanceInfoCase_ != CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
				{
					return null;
				}
				return (CellMonsterInfo)this.advanceInfo_;
			}
			set
			{
				this.advanceInfo_ = value;
				this.advanceInfoCase_ = ((value == null) ? CellAdvanceInfo.AdvanceInfoOneofCase.None : CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo);
			}
		}

		// Token: 0x1700054C RID: 1356
		// (get) Token: 0x0600121F RID: 4639 RVA: 0x00033F64 File Offset: 0x00032164
		// (set) Token: 0x06001220 RID: 4640 RVA: 0x00033F7D File Offset: 0x0003217D
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellMonsterSelectInfo SelectBossInfo
		{
			get
			{
				if (this.advanceInfoCase_ != CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
				{
					return null;
				}
				return (CellMonsterSelectInfo)this.advanceInfo_;
			}
			set
			{
				this.advanceInfo_ = value;
				this.advanceInfoCase_ = ((value == null) ? CellAdvanceInfo.AdvanceInfoOneofCase.None : CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo);
			}
		}

		// Token: 0x1700054D RID: 1357
		// (get) Token: 0x06001221 RID: 4641 RVA: 0x00033F94 File Offset: 0x00032194
		// (set) Token: 0x06001222 RID: 4642 RVA: 0x00033FAC File Offset: 0x000321AC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellFinalMonsterInfo FinalBossInfo
		{
			get
			{
				if (this.advanceInfoCase_ != CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
				{
					return null;
				}
				return (CellFinalMonsterInfo)this.advanceInfo_;
			}
			set
			{
				this.advanceInfo_ = value;
				this.advanceInfoCase_ = ((value == null) ? CellAdvanceInfo.AdvanceInfoOneofCase.None : CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo);
			}
		}

		// Token: 0x1700054E RID: 1358
		// (get) Token: 0x06001223 RID: 4643 RVA: 0x00033FC2 File Offset: 0x000321C2
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public CellAdvanceInfo.AdvanceInfoOneofCase AdvanceInfoCase
		{
			get
			{
				return this.advanceInfoCase_;
			}
		}

		// Token: 0x06001224 RID: 4644 RVA: 0x00033FCA File Offset: 0x000321CA
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void ClearAdvanceInfo()
		{
			this.advanceInfoCase_ = CellAdvanceInfo.AdvanceInfoOneofCase.None;
			this.advanceInfo_ = null;
		}

		// Token: 0x06001225 RID: 4645 RVA: 0x00033FDA File Offset: 0x000321DA
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as CellAdvanceInfo);
		}

		// Token: 0x06001226 RID: 4646 RVA: 0x00033FE8 File Offset: 0x000321E8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(CellAdvanceInfo other)
		{
			return other != null && (other == this || (object.Equals(this.CellBossInfo, other.CellBossInfo) && object.Equals(this.SelectBossInfo, other.SelectBossInfo) && object.Equals(this.FinalBossInfo, other.FinalBossInfo) && this.AdvanceInfoCase == other.AdvanceInfoCase && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x06001227 RID: 4647 RVA: 0x00034060 File Offset: 0x00032260
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
			{
				num ^= this.CellBossInfo.GetHashCode();
			}
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
			{
				num ^= this.SelectBossInfo.GetHashCode();
			}
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
			{
				num ^= this.FinalBossInfo.GetHashCode();
			}
			num ^= (int)this.advanceInfoCase_;
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x06001228 RID: 4648 RVA: 0x000340D6 File Offset: 0x000322D6
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x06001229 RID: 4649 RVA: 0x000340DE File Offset: 0x000322DE
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x0600122A RID: 4650 RVA: 0x000340E8 File Offset: 0x000322E8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
			{
				output.WriteRawTag(18);
				output.WriteMessage(this.FinalBossInfo);
			}
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
			{
				output.WriteRawTag(106);
				output.WriteMessage(this.SelectBossInfo);
			}
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
			{
				output.WriteRawTag(122);
				output.WriteMessage(this.CellBossInfo);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x0600122B RID: 4651 RVA: 0x00034164 File Offset: 0x00032364
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
			{
				num += 1 + CodedOutputStream.ComputeMessageSize(this.CellBossInfo);
			}
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
			{
				num += 1 + CodedOutputStream.ComputeMessageSize(this.SelectBossInfo);
			}
			if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
			{
				num += 1 + CodedOutputStream.ComputeMessageSize(this.FinalBossInfo);
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x0600122C RID: 4652 RVA: 0x000341D8 File Offset: 0x000323D8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CellAdvanceInfo other)
		{
			if (other == null)
			{
				return;
			}
			CellAdvanceInfo.AdvanceInfoOneofCase advanceInfoCase = other.AdvanceInfoCase;
			if (advanceInfoCase != CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
			{
				if (advanceInfoCase != CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
				{
					if (advanceInfoCase == CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
					{
						if (this.CellBossInfo == null)
						{
							this.CellBossInfo = new CellMonsterInfo();
						}
						this.CellBossInfo.MergeFrom(other.CellBossInfo);
					}
				}
				else
				{
					if (this.SelectBossInfo == null)
					{
						this.SelectBossInfo = new CellMonsterSelectInfo();
					}
					this.SelectBossInfo.MergeFrom(other.SelectBossInfo);
				}
			}
			else
			{
				if (this.FinalBossInfo == null)
				{
					this.FinalBossInfo = new CellFinalMonsterInfo();
				}
				this.FinalBossInfo.MergeFrom(other.FinalBossInfo);
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x0600122D RID: 4653 RVA: 0x00034285 File Offset: 0x00032485
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x0600122E RID: 4654 RVA: 0x00034290 File Offset: 0x00032490
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num != 18U)
				{
					if (num != 106U)
					{
						if (num != 122U)
						{
							this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
						}
						else
						{
							CellMonsterInfo cellMonsterInfo = new CellMonsterInfo();
							if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.CellBossInfo)
							{
								cellMonsterInfo.MergeFrom(this.CellBossInfo);
							}
							input.ReadMessage(cellMonsterInfo);
							this.CellBossInfo = cellMonsterInfo;
						}
					}
					else
					{
						CellMonsterSelectInfo cellMonsterSelectInfo = new CellMonsterSelectInfo();
						if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.SelectBossInfo)
						{
							cellMonsterSelectInfo.MergeFrom(this.SelectBossInfo);
						}
						input.ReadMessage(cellMonsterSelectInfo);
						this.SelectBossInfo = cellMonsterSelectInfo;
					}
				}
				else
				{
					CellFinalMonsterInfo cellFinalMonsterInfo = new CellFinalMonsterInfo();
					if (this.advanceInfoCase_ == CellAdvanceInfo.AdvanceInfoOneofCase.FinalBossInfo)
					{
						cellFinalMonsterInfo.MergeFrom(this.FinalBossInfo);
					}
					input.ReadMessage(cellFinalMonsterInfo);
					this.FinalBossInfo = cellFinalMonsterInfo;
				}
			}
		}

		// Token: 0x04000781 RID: 1921
		private static readonly MessageParser<CellAdvanceInfo> _parser = new MessageParser<CellAdvanceInfo>(() => new CellAdvanceInfo());

		// Token: 0x04000782 RID: 1922
		private UnknownFieldSet _unknownFields;

		// Token: 0x04000783 RID: 1923
		public const int CellBossInfoFieldNumber = 15;

		// Token: 0x04000784 RID: 1924
		public const int SelectBossInfoFieldNumber = 13;

		// Token: 0x04000785 RID: 1925
		public const int FinalBossInfoFieldNumber = 2;

		// Token: 0x04000786 RID: 1926
		private object advanceInfo_;

		// Token: 0x04000787 RID: 1927
		private CellAdvanceInfo.AdvanceInfoOneofCase advanceInfoCase_;

		// Token: 0x020015E3 RID: 5603
		public enum AdvanceInfoOneofCase
		{
			// Token: 0x04006071 RID: 24689
			None,
			// Token: 0x04006072 RID: 24690
			CellBossInfo = 15,
			// Token: 0x04006073 RID: 24691
			SelectBossInfo = 13,
			// Token: 0x04006074 RID: 24692
			FinalBossInfo = 2
		}
	}
}
